home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 4 / Apprentice-Release4.iso / Source Code / C / Applications / MacPerl 5.0.3 / MacPerl Source ƒ / Perl5 / ext / IC / Makefile < prev    next >
Encoding:
Makefile  |  1995-08-23  |  5.9 KB  |  210 lines  |  [TEXT/MPS ]

  1. # This Makefile is for the DynaLoader extension to perl.
  2. #
  3.  
  4. # --- MakeMaker post_initialize section:
  5.  
  6.  
  7. # --- MakeMaker constants section:
  8.  
  9. NAME = InternetConfig
  10.  
  11. # Perl library to use when building the extension
  12. PERL_LIB = :::lib:
  13.  
  14. # Where is the perl source code located? (Eventually we should
  15. # be able to build extensions without requiring the perl source
  16. # but that's a way off yet).
  17. PERL_SRC = :::
  18. # Perl header files (will eventually be under PERL_LIB)
  19. PERL_INC = :::
  20. # Perl binaries
  21. PERL = :::miniperl
  22.  
  23. # FULLEXT = Pathname for extension directory (eg DBD/Oracle).
  24. # BASEEXT = Basename part of FULLEXT. May be just equal FULLEXT.
  25. # ROOTEXT = Directory part of FULLEXT with leading slash (eg /DBD)
  26. FULLEXT = InternetConfig
  27. BASEEXT = InternetConfig
  28. ROOTEXT = 
  29.  
  30. # Source code:
  31. XS= InternetConfig.xs
  32. C = InternetConfig.c
  33. H = 
  34.  
  35. PPCEXT = .c.o.PPC
  36. PPCOBJ = InternetConfig{PPCEXT} ICPPCGlue{PPCEXT}
  37. EXPEXT = .c.x
  38. PPCEXP = InternetConfig{EXPEXT}
  39.  
  40. # This extension may link to it's own library (see SDBM_File)
  41. PPC_Sys_Libraries = ":::PLib:Perl.xcoff" ∂
  42.                      "{PPCLibraries}"InterfaceLib.xcoff ∂
  43.                     "{PPCLibraries}"MathLib.xcoff ∂
  44.                     "{PPCLibraries}"StdCLib.xcoff ∂
  45.                     "{PPCLibraries}"StdCRuntime.o ∂
  46.                     "{PPCLibraries}"PPCCRuntime.o
  47.                     
  48. PPC_Lib_Equates = -l InterfaceLib.xcoff=InterfaceLib ∂
  49.                   -l MathLib.xcoff=MathLib ∂
  50.                   -l StdCLib.xcoff=StdCLib ∂
  51.                   -l Perl.xcoff=Perl ∂
  52.                   -l {BASEEXT}.xcoff={BASEEXT} 
  53.  
  54. # Where is the Config.pm that we are using/depend on
  55. CONFIGDEP = {PERL_ARCHLIB}Config.pm
  56.  
  57. # Where to put things:
  58. INST_LIBDIR     = {PERL_LIB}{ROOTEXT}
  59. INST_AUTODIR     = {PERL_LIB}auto:{FULLEXT}:
  60.  
  61. INST_BOOT    = {INST_AUTODIR}{BASEEXT}.bs
  62. INST_DYNAMIC = {INST_AUTODIR}{BASEEXT}
  63. INST_STATIC  = {BASEEXT}.o
  64. INST_PM          = {INST_LIBDIR}InternetConfig.pm
  65.  
  66.  
  67. # These definitions are from config.mac (via :::lib:Config.pm)
  68. SymOption    = -sym on
  69. PerlOption    =    -d MULTIPLICITY -d DEBUGGING
  70. COptions     = -m -mc68020 -r
  71. PPCCOptions = -shared_lib_export on -opt local -d macintosh -d __useAppleExts__ -appleext on
  72. LOptions     = -mf -w
  73. ROptions     = -i :
  74. CC68K         = C {SymOption} {PerlOption}
  75. CCPPC         = PPCC {SymOption} {PerlOption}
  76.  
  77. # Usage: {AUTOSPLITFILE} FileToSplit AutoDirToSplitInto
  78. AUTOSPLITFILE = {PERL} -I{PERL_LIB} -e 'use AutoSplit; AutoSplit::autosplit_file(${ARGV}[0], ${ARGV}[1], 0, 1, 1) ;'
  79.  
  80.  
  81. # --- MakeMaker tool_xsubpp section:
  82.  
  83. XSUBPP = {PERL_SRC}ext:xsubpp
  84. XSUBPPDEPS = {PERL_SRC}ext:typemap typemap
  85. XSUBPPARGS = -typemap {PERL_SRC}ext:typemap
  86.  
  87.  
  88. # --- MakeMaker tools_other section:
  89.  
  90. # The following is a portable way to say mkdir -p
  91. MKPATH = {PERL} -wle '$"="/"; foreach $p (@ARGV){ my(@p); foreach(split(/:/,$p)){ push(@p,${_}); next if -d "@p"; print "mkdir @p"; mkdir("@p",0777)||die $! }} exit 0;'
  92.  
  93.  
  94. # --- MakeMaker c_o section:
  95.  
  96. .c.o.68Kƒ    .c
  97.     {CC68K} {COptions} -i {PERL_INC} {INC} {Default}.c -o {Default}.c.o.68K
  98. .c.o.PPCƒ    .c
  99.     {CCPPC} {PPCCOptions} -i {PERL_INC} {INC} {Default}.c -o {Default}.c.o.PPC
  100.  
  101.  
  102. # --- MakeMaker xs_c section:
  103.  
  104. .c ƒ .xs
  105.     {PERL} {XSUBPP} {XSUBPPARGS} {Default}.xs >{Default}.c
  106.  
  107.  
  108. # --- MakeMaker top_targets section:
  109.  
  110. all ƒ dynamic {INST_PM}
  111.  
  112. install ƒ all
  113.  
  114. # --- MakeMaker static section:
  115.  
  116. # {INST_PM} has been moved to the all: target.
  117. # It remains here for awhile to allow for old usage: "make static"
  118. static ƒ {INST_STATIC}.PPC {INST_PM} 
  119.  
  120. {INST_STATIC}.PPCƒ {PPCOBJ}
  121.     PPCLink -sym on -o {INST_STATIC}.PPC -xm library {PPCOBJ}
  122.     
  123. # --- MakeMaker dynamic section:
  124.  
  125. # {INST_PM} has been moved to the all: target.
  126. # It remains here for awhile to allow for old usage: "make dynamic"
  127. dynamic ƒ {BASEEXT} {INST_PM} 
  128.     :::miniperl -e 'mkdir "'{INST_AUTODIR}'", 0777 unless -d "'{INST_AUTODIR}'"'
  129.     Duplicate -y {BASEEXT} {INST_DYNAMIC}
  130.     
  131. {BASEEXT}.xcoff ƒ {PPCOBJ}
  132.     PPCLink {SymOption} -o {BASEEXT}.xcoff -export `ConvertExportList {PPCEXP}` -xm SharedLibrary ∂
  133.         {PPCOBJ} {PPC_Sys_Libraries}
  134.     MakeSYM -cttes -i ::: -i ::::XL: {BASEEXT}.xcoff
  135. {BASEEXT} ƒ {BASEEXT}.xcoff
  136.     MakePEF {BASEEXT}.xcoff -o {BASEEXT} ∂
  137.             {PPC_Lib_Equates} ∂
  138.             -ft 'shlb' -fc 'cfrg'
  139. # --- MakeMaker installpm section:
  140.  
  141. # installpm: InternetConfig.pm => {INST_LIBDIR}InternetConfig.pm, splitlib={INST_LIBDIR}
  142.  
  143. {INST_LIBDIR}InternetConfig.pmƒ InternetConfig.pm
  144.     Delete -i -y {INST_LIBDIR}InternetConfig.pm
  145.     Duplicate InternetConfig.pm {INST_LIBDIR}InternetConfig.pm
  146.     {AUTOSPLITFILE} {INST_LIBDIR}InternetConfig.pm {INST_LIBDIR}auto
  147.  
  148.  
  149. clean ƒ
  150. #    rm -f *~ t/*~ *.o *.a mon.out core so_locations {BOOTSTRAP} {BASEEXT}.bso
  151.  
  152.  
  153. # --- MakeMaker realclean section:
  154.  
  155. # Delete temporary files (via clean) and also delete installed files
  156. #realclean purge ::  clean
  157. #    rm -f Makefile {INST_DYNAMIC} {INST_STATIC} {INST_BOOT} {INST_PM}
  158. #    rm -rf {INST_AUTODIR} {INST_ARCHAUTODIR}
  159.  
  160.  
  161. # --- MakeMaker distclean section:
  162.  
  163. # distclean:     clean
  164. #     @:
  165. #     rm -f ./Makefile
  166. # #     cd ..; tar cvf {DISTNAME}-{VERSION}.tar {BASEEXT}
  167. #    cd ..; compress {DISTNAME}-{VERSION}.tar
  168. #     @:
  169.  
  170.  
  171. # --- MakeMaker test section:
  172.  
  173. # test :: all
  174. #     @echo 'No tests defined for {NAME} extension.'
  175.  
  176.  
  177. # --- MakeMaker install section:
  178.  
  179. # install :: all
  180.     # install is not defined. Makefile, by default, builds the extension
  181.     # directly into {INST_LIB} so "installing" does not make much sense.
  182.     # If INST_LIB is in the perl source tree then installperl will install
  183.     # the extension when it installs perl.
  184.  
  185.  
  186. # --- MakeMaker force section:
  187. # Phony target to force checking subdirectories.
  188. # FORCE:
  189.  
  190.  
  191. # --- MakeMaker perldepend section:
  192.  
  193. PERL_HDRS = {PERL_INC}EXTERN.h {PERL_INC}INTERN.h ∂
  194.     {PERL_INC}XSUB.h    {PERL_INC}av.h    {PERL_INC}cop.h ∂
  195.     {PERL_INC}cv.h    {PERL_INC}dosish.h    {PERL_INC}embed.h ∂
  196.     {PERL_INC}form.h    {PERL_INC}gv.h    {PERL_INC}handy.h ∂
  197.     {PERL_INC}hv.h    {PERL_INC}keywords.h    {PERL_INC}mg.h ∂
  198.     {PERL_INC}op.h    {PERL_INC}opcode.h    {PERL_INC}patchlevel.h ∂
  199.     {PERL_INC}perl.h    {PERL_INC}perly.h    {PERL_INC}pp.h ∂
  200.     {PERL_INC}proto.h    {PERL_INC}regcomp.h    {PERL_INC}regexp.h ∂
  201.     {PERL_INC}scope.h    {PERL_INC}sv.h    {PERL_INC}unixish.h ∂
  202.     {PERL_INC}util.h
  203.  
  204. # {OBJECT} ƒ {PERL_HDRS}
  205.  
  206. # --- MakeMaker postamble section:
  207.  
  208.  
  209. # End.
  210.